﻿<Window x:Class="Notoric.Gui.Windows.ChangeTimeSignatureDialog"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:rb="clr-namespace:Fluent;assembly=Fluent"
        Title="Change Time Signature" Height="175" Width="370"
        Background="#FFF0F0F0" ResizeMode="NoResize" WindowStartupLocation="CenterScreen">
    <StackPanel>
        <Grid Background="White" Margin="7 7 7 0">
            <Grid.ColumnDefinitions>
                <ColumnDefinition/>
                <ColumnDefinition/>
                <ColumnDefinition/>
                <ColumnDefinition/>
                <ColumnDefinition/>
                <ColumnDefinition/>
                <ColumnDefinition/>
                <ColumnDefinition Width="100"/>
            </Grid.ColumnDefinitions>
            <Grid.RowDefinitions>
                <RowDefinition/>
                <RowDefinition/>
            </Grid.RowDefinitions>

            <RadioButton x:Name="PART_CommonType" GroupName="Signature" Grid.Column="0"  Margin="0 -0.4cm 0 0" IsChecked="True">
                <RadioButton.Content>
                    <TextBlock FontFamily="MusicalSymbols" FontSize="0.7cm" Text="c"/>
                </RadioButton.Content>
            </RadioButton>

            <RadioButton x:Name="PART_AllaBreveType" GroupName="Signature" Grid.Column="1"  Margin="0 -0.4cm 0 0">
                <RadioButton.Content>
                        <TextBlock FontFamily="MusicalSymbols" FontSize="0.7cm" Text="C"/>
                </RadioButton.Content>
            </RadioButton>
            
            <RadioButton x:Name="PART_44" GroupName="Signature" Grid.Column="2"  Margin="0 -0.7cm 0 0">
                <RadioButton.Content>
                    <StackPanel Orientation="Vertical">
                        <TextBlock FontFamily="MusicalSymbols" FontSize="0.7cm" Text="4"/>
                        <TextBlock FontFamily="MusicalSymbols" FontSize="0.7cm" Text="4" Margin="0 -1.4cm 0 0"/>
                    </StackPanel>
                </RadioButton.Content>
            </RadioButton>

            <RadioButton x:Name="PART_34" GroupName="Signature" Grid.Column="3"  Margin="0 -0.7cm 0 0">
                <RadioButton.Content>
                    <StackPanel Orientation="Vertical">
                        <TextBlock FontFamily="MusicalSymbols" FontSize="0.7cm" Text="3"/>
                        <TextBlock FontFamily="MusicalSymbols" FontSize="0.7cm" Text="4" Margin="0 -1.4cm 0 0"/>
                    </StackPanel>
                </RadioButton.Content>
            </RadioButton>

            <RadioButton x:Name="PART_22" GroupName="Signature" Grid.Column="4"  Margin="0 -0.7cm 0 0">
                <RadioButton.Content>
                    <StackPanel Orientation="Vertical">
                        <TextBlock FontFamily="MusicalSymbols" FontSize="0.7cm" Text="2"/>
                        <TextBlock FontFamily="MusicalSymbols" FontSize="0.7cm" Text="2" Margin="0 -1.4cm 0 0"/>
                    </StackPanel>
                </RadioButton.Content>
            </RadioButton>

            <RadioButton x:Name="PART_68" GroupName="Signature" Grid.Column="5"  Margin="0 -0.7cm 0 0">
                <RadioButton.Content>
                    <StackPanel Orientation="Vertical">
                        <TextBlock FontFamily="MusicalSymbols" FontSize="0.7cm" Text="6"/>
                        <TextBlock FontFamily="MusicalSymbols" FontSize="0.7cm" Text="8" Margin="0 -1.4cm 0 0"/>
                    </StackPanel>
                </RadioButton.Content>
            </RadioButton>

            <RadioButton x:Name="PART_98" GroupName="Signature" Grid.Column="6"  Margin="0 -0.7cm 0 0">
                <RadioButton.Content>
                    <StackPanel Orientation="Vertical">
                        <TextBlock FontFamily="MusicalSymbols" FontSize="0.7cm" Text="9"/>
                        <TextBlock FontFamily="MusicalSymbols" FontSize="0.7cm" Text="8" Margin="0 -1.4cm 0 0"/>
                    </StackPanel>
                </RadioButton.Content>
            </RadioButton>

            <RadioButton x:Name="PART_OtherType" GroupName="Signature" Grid.Column="7"  Margin="0 0 0 0">
                <RadioButton.Content>
                    <StackPanel Orientation="Horizontal">
                        <Label Content="Other:" VerticalAlignment="Center"/>
                        <StackPanel Orientation="Vertical">
                            <rb:Spinner x:Name="PART_Beats" Format="0" Width="50" Margin="-12 0 0 0" Minimum="1" Maximum="128" Value="4" IsEnabled="{Binding ElementName=PART_OtherType, Path=IsChecked}"/>
                            <ComboBox x:Name="PART_BeatUnit" Background="White" Width="40" Margin="0 0 0 0" SelectedIndex="2" IsEnabled="{Binding ElementName=PART_OtherType, Path=IsChecked}">
                                <ComboBoxItem Content="1"/>
                                <ComboBoxItem Content="2"/>
                                <ComboBoxItem Content="4"/>
                                <ComboBoxItem Content="8"/>
                                <ComboBoxItem Content="16"/>
                                <ComboBoxItem Content="32"/>
                                <ComboBoxItem Content="64"/>
                            </ComboBox>
                        </StackPanel>
                    </StackPanel>
                </RadioButton.Content>
            </RadioButton>
            
            <rb:Spinner x:Name="PART_FromMeasure" Grid.Row="1" Grid.Column="0" Grid.ColumnSpan="4" Format="0" Text="From Measure:" Width="120" Minimum="1" Maximum="{Binding MeasuresCount, Mode=OneWay}"/>
            <rb:Spinner x:Name="PART_ToMeasure" Grid.Row="1" Grid.Column="4" Grid.ColumnSpan="4" Format="0" Text="To Measure:" Width="110" Minimum="{Binding ElementName=PART_FromMeasure, Path=Value, Mode=OneWay}" 
                        Maximum="{Binding MeasuresCount, Mode=OneWay}" Value="{Binding MeasuresCount, Mode=OneTime}"/>
        </Grid>
        <StackPanel Orientation="Horizontal" HorizontalAlignment="Right" Margin="0 10 7 0">
            <Button x:Name="PART_OK" Width="60" Content="OK" IsDefault="True" Click="PART_OK_Click"/>
            <Button x:Name="PART_Cancel" Width="60" Margin="6 0 0 0" Content="Cancel" IsCancel="True" Click="PART_Cancel_Click"/>
        </StackPanel>
    </StackPanel>
</Window>
